package adapter;

import java.util.List;

import com.qzhy.female.R;

import android.content.Context;
import android.view.View;
import android.view.ViewGroup;
import android.widget.BaseAdapter;
import android.widget.TextView;

public class grideadapter extends BaseAdapter{
	
	private Context context;
	private List<String> date;

	public grideadapter(Context context,List<String> date) {
		this.context = context;
		this.date = date;
	}
	
	@Override
	public int getCount() {
		// TODO Auto-generated method stub
		return date.size();
	}

	@Override
	public Object getItem(int position) {
		// TODO Auto-generated method stub
		return null;
	}

	@Override
	public long getItemId(int position) {
		// TODO Auto-generated method stub
		return 0;
	}

	@Override
	public View getView(int position, View convertView, ViewGroup parent) {
		if(convertView==null){
			convertView=View.inflate(context, R.layout.item_home_gride_list	,null);
			TextView mTvTile=(TextView) convertView.findViewById(R.id.tv_model);
			mTvTile.setText(date.get(position));
		}
		return convertView;
	}
}
